package pack0806;
import java.util.Scanner;
public class DemoF {
    public static void main(String[] args){
        Scanner a = new Scanner(System.in);
        /*System.out.println("请输入一个数：");
        int b = a.nextInt();
        if(b%2==0){
            System.out.println("YES");
        }
        System.out.println("-------------------------");
        System.out.println("请输入一个数：");
        int c = a.nextInt();
        if(c%5==0 && c%7!=0){
            System.out.println("YES");
        }
        System.out.println("-------------------------");
        System.out.println("请输入一个数：");
        int d = a.nextInt();
        int e = (int)(Math.random()*100);
        if(d==e){
            System.out.println("YES");
        }
        System.out.println("-------------------------");
        System.out.println("请输入一个数：");
        int f = a.nextInt();
        if(f%5==0 && f%3==0){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
        System.out.println("-------------------------");
        System.out.println("请输入一个四位数：");
        int g = a.nextInt();
        int a1 = g/1000;
        int a2 = g/100%10;
        int a3 = g/10%10;
        int a4 = g%10;
        if(a1==a4 && a2==a3){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
        System.out.println("-------------------------");
        System.out.println("请输入一个时间：");
        int h = a.nextInt();
        int b1 = h/100;
        int b2 = h%100;
        if(b1<12 || b1==24){
            if (b1<12){
                System.out.print(b1);
                System.out.print(":");
                System.out.print(b2);
                System.out.println("AM");
            }else{
                System.out.print(b1-24);
                System.out.print(":");
                System.out.print(b2);
                System.out.println("AM");
            }
        }else{
            if (b1==12){
                System.out.print(b1);
                System.out.print(":");
                System.out.print(b2);
                System.out.println("PM");
            }else{
                System.out.print(b1-12);
                System.out.print(":");
                System.out.print(b2);
                System.out.println("PM");
            }
        }
        System.out.println("-------------------------");*/
        System.out.println("请输入一个三位数：");
        int i = a.nextInt();
        int c1 = i/100;
        int c2 = i/10%10;
        int c3 = i%10;
        double d1 = Math.pow(c1,3);
        double d2 = Math.pow(c2,3);
        double d3 = Math.pow(c3,3);
        if ((d1+d2+d3==i)){
            System.out.println("这个数是水仙花数。");
        }else{
            System.out.println("这个数不是水仙花数。");
        }
    }
}